Termination w.r.t. Q of the following Term Rewriting System could not be shown:

Q restricted rewrite system:
The TRS R consists of the following rules:

a__fact(X) → a__if(a__zero(mark(X)), s(0), prod(X, fact(p(X))))
a__add(0, X) → mark(X)
a__add(s(X), Y) → s(a__add(mark(X), mark(Y)))
a__prod(0, X) → 0
a__prod(s(X), Y) → a__add(mark(Y), a__prod(mark(X), mark(Y)))
a__if(true, X, Y) → mark(X)
a__if(false, X, Y) → mark(Y)
a__zero(0) → true
a__zero(s(X)) → false
a__p(s(X)) → mark(X)
mark(fact(X)) → a__fact(mark(X))
mark(if(X1, X2, X3)) → a__if(mark(X1), X2, X3)
mark(zero(X)) → a__zero(mark(X))
mark(prod(X1, X2)) → a__prod(mark(X1), mark(X2))
mark(p(X)) → a__p(mark(X))
mark(add(X1, X2)) → a__add(mark(X1), mark(X2))
mark(s(X)) → s(mark(X))
mark(0) → 0
mark(true) → true
mark(false) → false
a__fact(X) → fact(X)
a__if(X1, X2, X3) → if(X1, X2, X3)
a__zero(X) → zero(X)
a__prod(X1, X2) → prod(X1, X2)
a__p(X) → p(X)
a__add(X1, X2) → add(X1, X2)

Q is empty.


QTRS
  ↳ DependencyPairsProof

Q restricted rewrite system:
The TRS R consists of the following rules:

a__fact(X) → a__if(a__zero(mark(X)), s(0), prod(X, fact(p(X))))
a__add(0, X) → mark(X)
a__add(s(X), Y) → s(a__add(mark(X), mark(Y)))
a__prod(0, X) → 0
a__prod(s(X), Y) → a__add(mark(Y), a__prod(mark(X), mark(Y)))
a__if(true, X, Y) → mark(X)
a__if(false, X, Y) → mark(Y)
a__zero(0) → true
a__zero(s(X)) → false
a__p(s(X)) → mark(X)
mark(fact(X)) → a__fact(mark(X))
mark(if(X1, X2, X3)) → a__if(mark(X1), X2, X3)
mark(zero(X)) → a__zero(mark(X))
mark(prod(X1, X2)) → a__prod(mark(X1), mark(X2))
mark(p(X)) → a__p(mark(X))
mark(add(X1, X2)) → a__add(mark(X1), mark(X2))
mark(s(X)) → s(mark(X))
mark(0) → 0
mark(true) → true
mark(false) → false
a__fact(X) → fact(X)
a__if(X1, X2, X3) → if(X1, X2, X3)
a__zero(X) → zero(X)
a__prod(X1, X2) → prod(X1, X2)
a__p(X) → p(X)
a__add(X1, X2) → add(X1, X2)

Q is empty.

Using Dependency Pairs [1,13] we result in the following initial DP problem:
Q DP problem:
The TRS P consists of the following rules:

MARK(prod(X1, X2)) → MARK(X2)
MARK(prod(X1, X2)) → MARK(X1)
MARK(fact(X)) → MARK(X)
MARK(add(X1, X2)) → MARK(X2)
A__IF(false, X, Y) → MARK(Y)
A__FACT(X) → A__IF(a__zero(mark(X)), s(0), prod(X, fact(p(X))))
A__ADD(0, X) → MARK(X)
MARK(if(X1, X2, X3)) → MARK(X1)
A__FACT(X) → A__ZERO(mark(X))
A__ADD(s(X), Y) → A__ADD(mark(X), mark(Y))
A__IF(true, X, Y) → MARK(X)
A__FACT(X) → MARK(X)
A__P(s(X)) → MARK(X)
A__PROD(s(X), Y) → A__PROD(mark(X), mark(Y))
MARK(add(X1, X2)) → A__ADD(mark(X1), mark(X2))
MARK(p(X)) → MARK(X)
MARK(p(X)) → A__P(mark(X))
A__ADD(s(X), Y) → MARK(X)
A__PROD(s(X), Y) → MARK(X)
MARK(zero(X)) → MARK(X)
MARK(s(X)) → MARK(X)
MARK(add(X1, X2)) → MARK(X1)
A__ADD(s(X), Y) → MARK(Y)
A__PROD(s(X), Y) → MARK(Y)
MARK(prod(X1, X2)) → A__PROD(mark(X1), mark(X2))
A__PROD(s(X), Y) → A__ADD(mark(Y), a__prod(mark(X), mark(Y)))
MARK(if(X1, X2, X3)) → A__IF(mark(X1), X2, X3)
MARK(zero(X)) → A__ZERO(mark(X))
MARK(fact(X)) → A__FACT(mark(X))

The TRS R consists of the following rules:

a__fact(X) → a__if(a__zero(mark(X)), s(0), prod(X, fact(p(X))))
a__add(0, X) → mark(X)
a__add(s(X), Y) → s(a__add(mark(X), mark(Y)))
a__prod(0, X) → 0
a__prod(s(X), Y) → a__add(mark(Y), a__prod(mark(X), mark(Y)))
a__if(true, X, Y) → mark(X)
a__if(false, X, Y) → mark(Y)
a__zero(0) → true
a__zero(s(X)) → false
a__p(s(X)) → mark(X)
mark(fact(X)) → a__fact(mark(X))
mark(if(X1, X2, X3)) → a__if(mark(X1), X2, X3)
mark(zero(X)) → a__zero(mark(X))
mark(prod(X1, X2)) → a__prod(mark(X1), mark(X2))
mark(p(X)) → a__p(mark(X))
mark(add(X1, X2)) → a__add(mark(X1), mark(X2))
mark(s(X)) → s(mark(X))
mark(0) → 0
mark(true) → true
mark(false) → false
a__fact(X) → fact(X)
a__if(X1, X2, X3) → if(X1, X2, X3)
a__zero(X) → zero(X)
a__prod(X1, X2) → prod(X1, X2)
a__p(X) → p(X)
a__add(X1, X2) → add(X1, X2)

Q is empty.
We have to consider all minimal (P,Q,R)-chains.

↳ QTRS
  ↳ DependencyPairsProof
QDP
      ↳ EdgeDeletionProof

Q DP problem:
The TRS P consists of the following rules:

MARK(prod(X1, X2)) → MARK(X2)
MARK(prod(X1, X2)) → MARK(X1)
MARK(fact(X)) → MARK(X)
MARK(add(X1, X2)) → MARK(X2)
A__IF(false, X, Y) → MARK(Y)
A__FACT(X) → A__IF(a__zero(mark(X)), s(0), prod(X, fact(p(X))))
A__ADD(0, X) → MARK(X)
MARK(if(X1, X2, X3)) → MARK(X1)
A__FACT(X) → A__ZERO(mark(X))
A__ADD(s(X), Y) → A__ADD(mark(X), mark(Y))
A__IF(true, X, Y) → MARK(X)
A__FACT(X) → MARK(X)
A__P(s(X)) → MARK(X)
A__PROD(s(X), Y) → A__PROD(mark(X), mark(Y))
MARK(add(X1, X2)) → A__ADD(mark(X1), mark(X2))
MARK(p(X)) → MARK(X)
MARK(p(X)) → A__P(mark(X))
A__ADD(s(X), Y) → MARK(X)
A__PROD(s(X), Y) → MARK(X)
MARK(zero(X)) → MARK(X)
MARK(s(X)) → MARK(X)
MARK(add(X1, X2)) → MARK(X1)
A__ADD(s(X), Y) → MARK(Y)
A__PROD(s(X), Y) → MARK(Y)
MARK(prod(X1, X2)) → A__PROD(mark(X1), mark(X2))
A__PROD(s(X), Y) → A__ADD(mark(Y), a__prod(mark(X), mark(Y)))
MARK(if(X1, X2, X3)) → A__IF(mark(X1), X2, X3)
MARK(zero(X)) → A__ZERO(mark(X))
MARK(fact(X)) → A__FACT(mark(X))

The TRS R consists of the following rules:

a__fact(X) → a__if(a__zero(mark(X)), s(0), prod(X, fact(p(X))))
a__add(0, X) → mark(X)
a__add(s(X), Y) → s(a__add(mark(X), mark(Y)))
a__prod(0, X) → 0
a__prod(s(X), Y) → a__add(mark(Y), a__prod(mark(X), mark(Y)))
a__if(true, X, Y) → mark(X)
a__if(false, X, Y) → mark(Y)
a__zero(0) → true
a__zero(s(X)) → false
a__p(s(X)) → mark(X)
mark(fact(X)) → a__fact(mark(X))
mark(if(X1, X2, X3)) → a__if(mark(X1), X2, X3)
mark(zero(X)) → a__zero(mark(X))
mark(prod(X1, X2)) → a__prod(mark(X1), mark(X2))
mark(p(X)) → a__p(mark(X))
mark(add(X1, X2)) → a__add(mark(X1), mark(X2))
mark(s(X)) → s(mark(X))
mark(0) → 0
mark(true) → true
mark(false) → false
a__fact(X) → fact(X)
a__if(X1, X2, X3) → if(X1, X2, X3)
a__zero(X) → zero(X)
a__prod(X1, X2) → prod(X1, X2)
a__p(X) → p(X)
a__add(X1, X2) → add(X1, X2)

Q is empty.
We have to consider all minimal (P,Q,R)-chains.
We deleted some edges using various graph approximations

↳ QTRS
  ↳ DependencyPairsProof
    ↳ QDP
      ↳ EdgeDeletionProof
QDP
          ↳ DependencyGraphProof

Q DP problem:
The TRS P consists of the following rules:

MARK(prod(X1, X2)) → MARK(X2)
MARK(prod(X1, X2)) → MARK(X1)
MARK(fact(X)) → MARK(X)
MARK(add(X1, X2)) → MARK(X2)
A__FACT(X) → A__IF(a__zero(mark(X)), s(0), prod(X, fact(p(X))))
A__IF(false, X, Y) → MARK(Y)
MARK(if(X1, X2, X3)) → MARK(X1)
A__ADD(0, X) → MARK(X)
A__FACT(X) → A__ZERO(mark(X))
A__ADD(s(X), Y) → A__ADD(mark(X), mark(Y))
A__FACT(X) → MARK(X)
A__IF(true, X, Y) → MARK(X)
A__P(s(X)) → MARK(X)
A__PROD(s(X), Y) → A__PROD(mark(X), mark(Y))
MARK(add(X1, X2)) → A__ADD(mark(X1), mark(X2))
MARK(p(X)) → MARK(X)
MARK(p(X)) → A__P(mark(X))
A__ADD(s(X), Y) → MARK(X)
A__PROD(s(X), Y) → MARK(X)
MARK(zero(X)) → MARK(X)
MARK(add(X1, X2)) → MARK(X1)
MARK(s(X)) → MARK(X)
A__ADD(s(X), Y) → MARK(Y)
A__PROD(s(X), Y) → MARK(Y)
MARK(prod(X1, X2)) → A__PROD(mark(X1), mark(X2))
MARK(zero(X)) → A__ZERO(mark(X))
MARK(if(X1, X2, X3)) → A__IF(mark(X1), X2, X3)
A__PROD(s(X), Y) → A__ADD(mark(Y), a__prod(mark(X), mark(Y)))
MARK(fact(X)) → A__FACT(mark(X))

The TRS R consists of the following rules:

a__fact(X) → a__if(a__zero(mark(X)), s(0), prod(X, fact(p(X))))
a__add(0, X) → mark(X)
a__add(s(X), Y) → s(a__add(mark(X), mark(Y)))
a__prod(0, X) → 0
a__prod(s(X), Y) → a__add(mark(Y), a__prod(mark(X), mark(Y)))
a__if(true, X, Y) → mark(X)
a__if(false, X, Y) → mark(Y)
a__zero(0) → true
a__zero(s(X)) → false
a__p(s(X)) → mark(X)
mark(fact(X)) → a__fact(mark(X))
mark(if(X1, X2, X3)) → a__if(mark(X1), X2, X3)
mark(zero(X)) → a__zero(mark(X))
mark(prod(X1, X2)) → a__prod(mark(X1), mark(X2))
mark(p(X)) → a__p(mark(X))
mark(add(X1, X2)) → a__add(mark(X1), mark(X2))
mark(s(X)) → s(mark(X))
mark(0) → 0
mark(true) → true
mark(false) → false
a__fact(X) → fact(X)
a__if(X1, X2, X3) → if(X1, X2, X3)
a__zero(X) → zero(X)
a__prod(X1, X2) → prod(X1, X2)
a__p(X) → p(X)
a__add(X1, X2) → add(X1, X2)

Q is empty.
We have to consider all minimal (P,Q,R)-chains.
The approximation of the Dependency Graph [13,14,18] contains 1 SCC with 2 less nodes.

↳ QTRS
  ↳ DependencyPairsProof
    ↳ QDP
      ↳ EdgeDeletionProof
        ↳ QDP
          ↳ DependencyGraphProof
QDP

Q DP problem:
The TRS P consists of the following rules:

MARK(prod(X1, X2)) → MARK(X2)
MARK(prod(X1, X2)) → MARK(X1)
MARK(fact(X)) → MARK(X)
MARK(add(X1, X2)) → MARK(X2)
A__IF(false, X, Y) → MARK(Y)
A__FACT(X) → A__IF(a__zero(mark(X)), s(0), prod(X, fact(p(X))))
A__ADD(0, X) → MARK(X)
MARK(if(X1, X2, X3)) → MARK(X1)
A__ADD(s(X), Y) → A__ADD(mark(X), mark(Y))
A__FACT(X) → MARK(X)
A__IF(true, X, Y) → MARK(X)
A__P(s(X)) → MARK(X)
A__PROD(s(X), Y) → A__PROD(mark(X), mark(Y))
MARK(add(X1, X2)) → A__ADD(mark(X1), mark(X2))
MARK(p(X)) → MARK(X)
MARK(p(X)) → A__P(mark(X))
A__ADD(s(X), Y) → MARK(X)
A__PROD(s(X), Y) → MARK(X)
MARK(zero(X)) → MARK(X)
MARK(add(X1, X2)) → MARK(X1)
MARK(s(X)) → MARK(X)
A__ADD(s(X), Y) → MARK(Y)
A__PROD(s(X), Y) → MARK(Y)
MARK(prod(X1, X2)) → A__PROD(mark(X1), mark(X2))
A__PROD(s(X), Y) → A__ADD(mark(Y), a__prod(mark(X), mark(Y)))
MARK(if(X1, X2, X3)) → A__IF(mark(X1), X2, X3)
MARK(fact(X)) → A__FACT(mark(X))

The TRS R consists of the following rules:

a__fact(X) → a__if(a__zero(mark(X)), s(0), prod(X, fact(p(X))))
a__add(0, X) → mark(X)
a__add(s(X), Y) → s(a__add(mark(X), mark(Y)))
a__prod(0, X) → 0
a__prod(s(X), Y) → a__add(mark(Y), a__prod(mark(X), mark(Y)))
a__if(true, X, Y) → mark(X)
a__if(false, X, Y) → mark(Y)
a__zero(0) → true
a__zero(s(X)) → false
a__p(s(X)) → mark(X)
mark(fact(X)) → a__fact(mark(X))
mark(if(X1, X2, X3)) → a__if(mark(X1), X2, X3)
mark(zero(X)) → a__zero(mark(X))
mark(prod(X1, X2)) → a__prod(mark(X1), mark(X2))
mark(p(X)) → a__p(mark(X))
mark(add(X1, X2)) → a__add(mark(X1), mark(X2))
mark(s(X)) → s(mark(X))
mark(0) → 0
mark(true) → true
mark(false) → false
a__fact(X) → fact(X)
a__if(X1, X2, X3) → if(X1, X2, X3)
a__zero(X) → zero(X)
a__prod(X1, X2) → prod(X1, X2)
a__p(X) → p(X)
a__add(X1, X2) → add(X1, X2)

Q is empty.
We have to consider all minimal (P,Q,R)-chains.